package csd.wyaiyr.com.config;

import lombok.Data;

@Data
public class SysException extends RuntimeException {

    private Integer code;

    private String errMsg;

    /**
     * 通过状态码和错误消息创建异常对象
     *
     * @param message
     * @param code
     */
    public SysException(Integer code, String message) {
        super(message);
        this.code = code;
    }

    public SysException(String message) {
        super(message);
        this.code = code;
    }

}
